Skip to main content

createArray

Creates an array value, an analogue of new Array (length) in JS.

Please note, that for the .docbuilder file the CDocBuilderContext.createArray method is not used.

Syntax

CDocBuilderValue createArray(int length);

Parameters

ParameterTypeDescription
lengthintThe array length.

Example

Java

CDocBuilder.initialize("");
CDocBuilder builder = new CDocBuilder();
CDocBuilderContext context = builder.getContext();
CDocBuilderValue arrayValue = context.createArray(2);
CDocBuilder.dispose();